<ui:composition xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    xmlns:p="http://primefaces.org/ui"
    xmlns:f="http://java.sun.com/jsf/core"
    template="/WEB-INF/templates/baseLayout.xhtml">

	<ui:define name="title">
		<h:outputText value="DAMATE - #{msg['TabPanel.manager']}" />
	</ui:define>

    <ui:define name="toolbar">
        <p:commandLink title="#{msg['managerPage.toolbar.newSubject']}" action="#{sectionManager.openPanel('NEW_SECTION')}" update="@form">
            <h:graphicImage library="images" name="add-subject-32.png" />
        </p:commandLink>
        <p:commandLink title="#{msg['managerPage.toolbar.showSubjects']}" action="#{sectionManager.openPanel('LIST_SECTIONS')}" update="@form">
            <h:graphicImage library="images" name="list-subjects-32.png" />
        </p:commandLink>
        <p:commandLink title="#{msg['managerPage.toolbar.newTask']}" action="#{taskManager.openPanel('NEW_TASK')}" update="@form">
            <h:graphicImage library="images" name="add-task-32.png" />
        </p:commandLink>
        <p:commandLink title="#{msg['managerPage.toolbar.showTasks']}" action="#{taskManager.openPanel('LIST_TASKS')}" update="@form">
            <h:graphicImage library="images" name="list-tasks-32.png" />
        </p:commandLink>
        <p:commandLink title="#{msg['managerPage.toolbar.newTeam']}" action="#{teamManager.openPanel('NEW_TEAM')}" update="@form">
            <h:graphicImage library="images" name="add-team-32.png" />
        </p:commandLink>
        <p:commandLink title="#{msg['managerPage.toolbar.showTeams']}" action="#{teamManager.openPanel('LIST_TEAMS')}" update="@form">
            <h:graphicImage library="images" name="list-teams-32.png" />
        </p:commandLink>
	</ui:define>

    <ui:define name="manager">
        <p:panel styleClass="imgHeader descriptionPanel" rendered="#{managerView.activePanel == 'DESCRIPTION'}">
            <f:facet name="header">
                <h:graphicImage library="images" name="subject-16.png" style="margin-top: 2px" />
                <h:outputText styleClass="title" value="#{msg['managerPage.sectionAndTeamManagement.title']}" />
            </f:facet>
            <h:outputText value="Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque id nunc ut justo venenatis tincidunt. Morbi sit amet nisi sapien. Maecenas porta pulvinar tellus eu semper. Quisque laoreet elit blandit nisl malesuada vitae dapibus lacus dapibus. Cras turpis dui, tristique a rhoncus ac, ullamcorper et urna. Pellentesque feugiat posuere ipsum, eu vehicula dui vestibulum ullamcorper. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam lobortis dolor eget nisi interdum dignissim." />
            <h:panelGroup layout="block" styleClass="funcDescription">
                <h:graphicImage library="images" name="add-subject-32.png" />
                <h:outputText value="#{msg['managerPage.toolbar.newSubject']}" styleClass="title" />
                <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque id nunc ut justo venenatis tincidunt. Morbi sit amet nisi sapien. Maecenas porta pulvinar tellus eu semper. Quisque laoreet elit blandit nisl malesuada vitae dapibus lacus dapibus. Cras turpis dui, tristique a rhoncus ac, ullamcorper et urna.</p>
            </h:panelGroup>
            <h:panelGroup layout="block" styleClass="funcDescription">
                <h:graphicImage library="images" name="list-subjects-32.png" />
                <h:outputText value="#{msg['managerPage.toolbar.showSubjects']}" styleClass="title" />
                <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque id nunc ut justo venenatis tincidunt. Morbi sit amet nisi sapien. Maecenas porta pulvinar tellus eu semper. Quisque laoreet elit blandit nisl malesuada vitae dapibus lacus dapibus. Cras turpis dui, tristique a rhoncus ac, ullamcorper et urna.</p>
            </h:panelGroup>
            <h:panelGroup layout="block" styleClass="funcDescription">
                <h:graphicImage library="images" name="add-task-32.png" />
                <h:outputText value="#{msg['managerPage.toolbar.newTask']}" styleClass="title" />
                <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque id nunc ut justo venenatis tincidunt. Morbi sit amet nisi sapien. Maecenas porta pulvinar tellus eu semper. Quisque laoreet elit blandit nisl malesuada vitae dapibus lacus dapibus. Cras turpis dui, tristique a rhoncus ac, ullamcorper et urna.</p>
            </h:panelGroup>
            <h:panelGroup layout="block" styleClass="funcDescription">
                <h:graphicImage library="images" name="list-tasks-32.png" />
                <h:outputText value="#{msg['managerPage.toolbar.showTasks']}" styleClass="title" />
                <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque id nunc ut justo venenatis tincidunt. Morbi sit amet nisi sapien. Maecenas porta pulvinar tellus eu semper. Quisque laoreet elit blandit nisl malesuada vitae dapibus lacus dapibus. Cras turpis dui, tristique a rhoncus ac, ullamcorper et urna.</p>
            </h:panelGroup>
            <h:panelGroup layout="block" styleClass="funcDescription">
                <h:graphicImage library="images" name="add-team-32.png" />
                <h:outputText value="#{msg['managerPage.toolbar.newTeam']}" styleClass="title" />
                <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque id nunc ut justo venenatis tincidunt. Morbi sit amet nisi sapien. Maecenas porta pulvinar tellus eu semper. Quisque laoreet elit blandit nisl malesuada vitae dapibus lacus dapibus. Cras turpis dui, tristique a rhoncus ac, ullamcorper et urna.</p>
            </h:panelGroup>
            <h:panelGroup layout="block" styleClass="funcDescription">
                <h:graphicImage library="images" name="list-teams-32.png" />
                <h:outputText value="#{msg['managerPage.toolbar.showTeams']}" styleClass="title" />
                <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque id nunc ut justo venenatis tincidunt. Morbi sit amet nisi sapien. Maecenas porta pulvinar tellus eu semper. Quisque laoreet elit blandit nisl malesuada vitae dapibus lacus dapibus. Cras turpis dui, tristique a rhoncus ac, ullamcorper et urna.</p>
            </h:panelGroup>
        </p:panel>
        <ui:include src="/WEB-INF/management/newSectionPanel.xhtml" />
        <ui:include src="/WEB-INF/management/sectionsPanel.xhtml" />
        <ui:include src="/WEB-INF/management/newTaskPanel.xhtml" />
        <ui:include src="/WEB-INF/management/tasksPanel.xhtml" />
        <ui:include src="/WEB-INF/management/newTeamPanel.xhtml" />
        <ui:include src="/WEB-INF/management/teamsPanel.xhtml" />
	</ui:define>

    <ui:define name="onAfterPageLoad">
        <script type="text/javascript" language="JavaScript">
            $(document).ready(function (){
                selectTab("manager");
            });
        </script>
    </ui:define>
</ui:composition>
